<!DOCTYPE html>
<html>
<head>
    <meta charset="UTF-8">
    <title>骚</title>
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
    <meta name="renderer" content="webkit">
    <meta name="csrf-token" content="{{ csrf_token() }}">
    <link rel="stylesheet" href="{{ asset('vaeyo/layui/css/layui.css') }}"  media="all">
    <style type="text/css">
        /*body{
            background:url('/themes/admin_themes/lib/vaeyo/img/bg.jpg');
        }*/
       /* .vaeyo-login-body{
            min-width:300px;
            max-width:400px;
            min-height:150px;
            margin:0 auto;
            margin-top:150px
        }
        .vaeyo-login-body h2{
            margin: 20px auto;
            text-align: center;
            font-size: 32px;
        }*/
        body {margin:0 auto;
            overflow:hidden;

        }

        /*=============第一页=============*/
        .header{
            margin:0 auto;
            width:100%;
            height:640px;
            background-color:#000;
            position:relative;
        }
        .header canvas {
            width:100%;height:auto/*默认全屏显示 可自己设置高度640px*/;
            display:inline-block;vertical-align:baseline;
            position:absolute;
            z-index:0;
        }
        .header .canvaszz{  /*用来解决视频右键菜单，用于视频上面的遮罩层*/
            width:100%;
            background-image: url({{ asset('images/in_top_bj.jpg') }});
            height:640px;
            position:absolute;
            z-index:10;
            filter:alpha(opacity=40);
            -moz-opacity:0.4;
            -khtml-opacity: 0.4;
            opacity: 0.4;
        }
        .form{
            width:300px;
            height:200px;
            /*border:1px solid #fff;*/
            position:absolute;
            z-index:30;
            top:200px;
            left: 50%;
            margin-left: -160px;
        }
        .form .layui-form .layui-input{
            background-color: transparent;
            color:#066197;
            border:1px solid #066197;
            margin-bottom: 15px;
        }
        .submit{
            text-decoration:none;
            width: 300px;
            height: 43px;
            display: block;
            text-align:center;		/*水平居中*/
            line-height:43px;  /*上下居中*/
            cursor:pointer;
            float:left;/*左浮动*/
            font:18px/43px 'microsoft yahei'; color:#066197;
            border:1px solid #066197;
            background-color: transparent;
        }
    </style>
</head>
<body>
<div class="header">
    <h2>Sao</h2>
    <form class="layui-form form" id="vaeyo-login">
        <div class="layui-form-item">
            <input type="text" name="account" lay-verify="required" placeholder="账号" autocomplete="off" class="layui-input">
        </div>
        <div class="layui-form-item">
            <input type="password" name="password" lay-verify="required" placeholder="密码" autocomplete="off" class="layui-input">
        </div>
        <button class="layui-btn layui-btn-fluid layui-bg-cyan" lay-submit lay-filter="submit" id="vaeyo-login-submit">登陆</button>
    </form>
    <div class="canvaszz"> </div>
    <canvas id="canvas"></canvas>

</div>

<!--用来解决视频右键菜单，用于视频上面的遮罩层 START-->
<div class="videozz"></div>
<!--用来解决视频右键菜单，用于视频上面的遮罩层 END-->
<script  src='{{ asset('js/starry.js') }}'></script>
<script src="{{ asset('xman/layui/layui.js') }}" charset="utf-8"></script>
<script type="text/javascript">
    layui.use(['form','jquery','layer'], function () {
        var form = layui.form,
            layer = layui.layer,
            $ = layui.jquery;
        form.on('submit(submit)',function (data) {
            //防止csrf攻击
            $.ajaxSetup({
                headers: {
                    'X-CSRF-TOKEN': $('meta[name="csrf-token"]').attr('content')
                }
            });
            var lIndex=layer.load();
            $.post('{{ url('admin/login') }}',data.field,function (res) {
                layer.close(lIndex);
                if(res.status == 200){
                    layer.msg(res.msg,{time:1500,icon:6},function () {
                        window.location.href = '{{ url('admin') }}';
                    });
                }else {
                    layer.msg(res.msg,{time:1500,icon:5});
                }
            },'json');
           return false;
        });
    });
</script>
</body>
</html>